php forum
php mysql forum
php mysql smarty
 
Topic Options
#273218 - 05/11/04 08:51 PM Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0
Sheall Offline
User

Registered: 05/25/02
Posts: 41
Mod Name / Version: Per-Forum Attachments - Version 1.0 <br /><br />Description: A modification that allows admins the option of allowing file attachments on posts in specific forums only. <br /><br />Working Under: UBB.Threads 6.3-6.4 <br /><br />Mod Status: Finished <br /><br />Any pre-requisites: None <br /><br />Author(s): Sheallaidh <br /><br />Date: 05/11/04 <br /><br />Credits: Me and a half a pack of Embassy Number 1 <br /><br />Files Altered:<br />./ubbthreads/addpost.php<br />./ubbthreads/modifypost.php<br />./ubbthreads/newpost.php<br />./ubbthreads/newreply.php<br />./ubbthreads/admin/createboard.php<br />./ubbthreads/admin/docreate.php<br />./ubbthreads/admin/viewboard.php<br />./ubbthreads/admin/doeditboard.php<br />./ubbthreads/languages/english/default/admin/createboard.php<br />./ubbthreads/languages/english/default/admin/Viewboard.php <br /><br />New Files: None. <br /><br />Database Altered: w3t_Boards (column added) <br /><br />Info/Instructions:<br />1. Follow the modification instructions attached.<br />2. Go to your admin area and choose edit config settings.<br />3. Turn on file attachments by specifying a writeable folder, and the URL.<br />4. Set the maximum allowed size of attachments.<br />5. Set what file types to allow.<br />6. Click the update config.inc.php button.<br />7. Using the edit forum tool, allow file attachments to any or all forums.<br /><br />NOTE: Allowing file attachments is set to OFF by default on any existing forums. <br /><br />Disclaimer: Please backup every file that you intend to modify. <br />If the modification modifies the database, it's a good idea to backup your database before doing so. <br /><br />Note: If you modify your UBB.Threads code, you may be giving up your right for "official" support from Infopop.If you need official support, you'll need to restore unmodified files.


Attachments
113052-attachment forum choice.txt (33 downloads)


Top
#273219 - 05/11/04 11:19 PM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: tanster]
AllenAyres Offline

I type Like navaho

Registered: 03/10/00
Posts: 25580
Loc: Texas
Don't have time to test this right now, but thanks, looks like a good modification <img src="http://www.ubbdev.com/forum/images/graemlins/smile.gif" alt="" />
_________________________
- Allen wavey
- What Drives You?

Top
#273220 - 05/12/04 02:05 PM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: SurfMinister]
smilesforu Offline
Junior Member

Registered: 01/31/02
Posts: 676
Great idea thanks for the mod.. I can't get to testing this one for awhile either.

Top
#273221 - 05/17/04 10:29 AM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: Kelly]
Gregori Offline
Member

Registered: 09/14/02
Posts: 157
Great mod!<br /><br />Would it be possible for the different forums to use separate file catalogs?<br /><br />What I mean is this:<br /><br />I would like some forums to have theis own catalogs for attachements. These should only be accesseble by users who have access to the certain forum, and not open to everyone, like the default catalog.<br /><br />Would be cool to have when I later on will by the PayPal-mod.

Top
#273222 - 05/19/04 07:26 AM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: tubedogg_dup1]
Sheall Offline
User

Registered: 05/25/02
Posts: 41
Yes, but I as it is outwith the scope of what I want to do with the website I am working on at the moment, I wont be create the modifcation.<br /><br />Perhaps you could ask someone for hire?

Top
#273223 - 05/29/04 02:49 PM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: tanster]
Deejay_dup1 Offline
Journeyman

Registered: 08/25/02
Posts: 106
Wondering if it would be a simple add in or edit to this mod to only allow certain groups to post the attachments, on any given forum? <br /> <br />To basicly only allow groups 5 to 8 the permission to post attachments for instance? (Didnt see a mod like this when searching, hope i didnt miss it) <br /> <br />Looks like the first edit mentions group 4... would it just be adding the other groups to that (and taking the 4 out?) what would be the code exactly? (Im real green at programming) <br /> <br />

Top
#273224 - 05/30/04 12:25 AM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: darenu]
Deejay_dup1 Offline
Journeyman

Registered: 08/25/02
Posts: 106
This section in adduser.php seems to be where it decides permissions to post attachments? Yes? No? <br /> <br />// ------------------------------------------------------------------------- <br /> // If we are allowing file attachments and we are dealing with a Mozilla 4+ <br /> // browser then we let them attach files. Also we need to make sure they <br /> // are not posting as Anon. <br /> if( ($Attach == "On") && ($Reged == "y")) { <br /> $attachfile = "<br /><br />{$ubbt_lang['YES_FILE2']}"; <br /> $fileinput ="<input type=\"file\" name=\"userfile\" accept=\"*\" class=\"formboxes\" size=\"60\" />"; <br /> } <br /> <br /> <br />This line: <br /> if( ($Attach == "On") && ($Reged == "y")) <br /> <br /> <br />Im not sure how to do it, but adding more arguements to it will do it right? <br /> <br />Like if it said "if attach is on, and reged is yes, AND group is 5 OR 6 OR 7 OR 8" then it is allowed??? <br /> <br />Can someone who knows php more than me make/modify that line of code so I can try it? <br /> <br />Will it work the way I think it will, only allowing users in those groups to post attachments? <br /> <br />It looks like the same if/then line I am asking for help on might need to be added/edited to other parts of this mod too, whereever it says the if reg'd and attach=on? <br /> <br />This would be great for you guys out there like myself who run donation/supporter software for supporting members. <br /> <br />Deej

Top
#273225 - 06/02/04 10:39 PM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: darenu]
Deejay_dup1 Offline
Journeyman

Registered: 08/25/02
Posts: 106
I made this real easy for what I wanted. <br /> <br />Since i was allowing attachments to any forums, I only needed to change who was allowed to.. I only wanted certain groups to have the ability to upload... <br /> <br />SO I only changed the strings which checked the user, in the post modifying scripts, and it now locks out any user who isnt in my supporting groups, from adding attachments. <img src="http://www.ubbdev.com/forum/images/graemlins/wink.gif" alt="" /> <br /> <br />Deej


Edited by Deejay (06/02/04 10:40 PM)

Top
#273226 - 06/09/04 04:07 PM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: darenu]
smilesforu Offline
Junior Member

Registered: 01/31/02
Posts: 676
Deej is this the one you just posted or additional steps? 6.4.2

Top
#273227 - 06/09/04 06:01 PM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: Kelly]
Deejay_dup1 Offline
Journeyman

Registered: 08/25/02
Posts: 106
I just modified this mod... <img src="http://www.ubbdev.com/forum/images/graemlins/wink.gif" alt="" /> Only had to modify the scripts that add or modify posts. (addpost, modifypost etc)<br /><br />Just changed the lines in the scripts that figure out what users are allowed to post attachments. I added in the groups I wanted, and took out the ones I didnt.<br /><br />This mod the way its posted is a lot more in depth than what I just did... This mod is made to restrict them per forum... and also there is selections available through the admin panel. What I did stripped out all that stuff.<br /><br />Deej

Top
#273228 - 07/21/04 05:06 PM Re: Finished-[6.3-6.4] Per-Forum Attachments - Version 1.0 [Re: darenu]
Sheall Offline
User

Registered: 05/25/02
Posts: 41
I am glad SOMEONE actually used it <img src="http://www.ubbdev.com/forum/images/graemlins/laugh.gif" alt="" /><br /><br />It's the first real "hack" that I've not been able to find anywhere online, and had to resort to writing myself. <img src="http://www.ubbdev.com/forum/images/graemlins/blush.gif" alt="" />

Top



Moderator:  Ian_W 
Latest Posts
[7.2.1] - Naked shoutbox
by bellaonline
05/05/12 05:00 PM
[7.x] Stop Forum Spam Integration v0.4
by bellaonline
05/05/12 03:53 PM
Shout Box

(Views)Popular Topics
Known public proxy servers 1689885
Integrated Index Page (IIP) 5.3.1 555705
Finished-[6.5.2] Games Arcade Deluxe v1.9 501236
Integrated Index Page (IIP) 5.1.1 415112
TLD Bv2.1 Released - Threads Links Directory 396822
[6.0x] Who's Online 4.0.0 [Finished] 389412
Finished-[6.5.1] Integrated Index Page (IIP) 6.5 330423
Q & A 298663
Slash UBB 266936
[6.3.x] [beta] Hit Hack 2.0 227970
Forum Stats
13621 Members
59 Forums
37191 Topics
295716 Posts

Max Online: 686 @ 06/28/07 07:04 AM

 

 

 
fusionbb message board php hacks